#!/usr/bin/python
# -*- coding: utf-8 -*-
# @Time    : 2018/8/13 10:16
# @Author  : hyang
# @File    : settings.py
# @Software: PyCharm
import os

BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))

DOC_DIR = os.path.join(BASE_DIR, 'doc')

# 日志参数
LOG_FILE = os.path.join(BASE_DIR, 'log', 'sfa_access.log')

MAX_BYTES_EACH = 1024 * 1000

BACKUP_COUNT = 10

LOGGER_NAME = 'access'

FMT = '%(asctime)s - %(name)s - %(filename)s[line: %(lineno)d] %(levelname)s: %(message)s'

DATE_FMT = '%Y-%m-%d %H:%M:%S'
LOG_LEVEL_IN_CONSOLE = 10
# 日志级别：CRITICAL = 50 ERROR = 40 WARNING = 30 INFO = 20 DEBUG = 10 NOTSET = 0
LOG_LEVEL_IN_FILE = 10
# CONSOLE_LOG_ON  = 1 开启控制台日志，FILE_LOG_ON = 1 开启文件日志
CONSOLE_LOG_ON = 1

FILE_LOG_ON = 1


# mysqldb参数

mysqldb = {
    'host': '10.1.204.128',
    'port': 3306,
    'user': 'yycenter',
    'password': 'qwe123',
    'database': 'testmysql',
    'charset': 'utf8'
}
